<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
        <link href="./css/default.css" type="text/css" rel="stylesheet">
        <title></title>
        <script type="text/javascript" src="./js/plugins/jquery-1.6.1.min.js"></script>
        <script type="text/javascript" src="./js/plugins/jquery.json.js"></script>
        <script type="text/javascript" src="./js/uncompressed/jpost-1.0.js"></script>
        <script type="text/javascript">
             
          $(document).ready(function(){

             $(".button").click(function(){               
                
                request = {
                    o : $("input[name^='hotel']").toObject(),
                    action: 'propertyList'
                }

                jpost.send(request,'properties',function(result){

                        $("#name").val(result[0].name);
                        $("#adress").val(result[0].adress);
                        $("#phone").val(result[0].phone);
                        $("#mail").val(result[0].mail);
                        $("#name").val(result[0].name);
                        $("#name").val(result[0].name);
                });

             });
             
            })

        </script>
    </head>
    <body>
        <div>
            <header></header>
            <section>
                 <!-- FORM HOTEL -->
                <div class="data-form">
                    <div class="data-form-line">
                        <span class="text-follow-input">Hotel</span>
                        <input type="text" name="hotel" id="name">
                      <ul class="stars" >
                           <li class="one"></li>
                           <li class="two"></li>
                           <li class="trhee"></li>
                           <li class="four"></li>
                           <li class="five"></li>
                        </ul>
                    </div>
                    <div class="data-form-line">
                        <span class="text-follow-input">Dirección</span>
                        <input type="text" id="adress" name="hotel" >
                    </div>
                    <div class="data-form-line">
                        <span class="text-follow-input">Telefono</span>
                        <input type="text" id="phone" name="hotel" >
                    </div>
                    <div class="data-form-line">
                        <span class="text-follow-input">E-Mail</span>
                        <input type="text" id="mail"  name="hotel">
                    </div>
                    <div class="data-form-line">
                        <span class="text-follow-input">Huesped</span>
                        <input type="text" id="x"  name="cardex">
                    </div>
                      <div class="data-form-line">
                        <span class="text-follow-input">Huesped</span>
                        <input type="text" id="id"  name="hotel">
                    </div>

                     <div  class="button">
                        <span class="plus"></span> <strong>Añadir</strong>
                    </div>
                </div>
               <!-- FORM HOTEL -->
               


            </section>
        </div>
    </body>
</html>
